//
//  RMMXiuGaiPasswordView.m
//  Romomo
//
//  Created by puman on 2016/12/14.
//  Copyright © 2016年 mazegong. All rights reserved.
//

#import "RMMXiuGaiPasswordView.h"

@implementation RMMXiuGaiPasswordView
- (instancetype)initWithFrame:(CGRect)frame{
    if (self = [super initWithFrame:frame]) {
        self.backgroundColor = kCColor;
        NSArray *plArr = @[@"请输入旧密码",@"请输入新密码",@"请再次输入新密码"];
        for (int i = 0; i < 3; i++) {
            UIView *view = [[UIView alloc] initWithFrame:CGRectMake(0, 16 + 55 * i, kScreenWideth, 54)];
            view.backgroundColor = kWhiteColor;
            [self addSubview:view];
            
            UITextField *textF = [[UITextField alloc] initWithFrame:CGRectMake(15, 0, view.width - 30, view.height)];
            textF.secureTextEntry = YES;
            textF.font = kFont(14);
            textF.placeholder = plArr[i];
            textF.clearButtonMode = UITextFieldViewModeWhileEditing;
            [view addSubview:textF];
            switch (i) {
                case 0:
                    _oldPassword = textF;
                    break;
                case 1:
                    _nePassword = textF;
                    break;
                case 2:
                    _againPassword = textF;
                    break;

                    
                default:
                    break;
            }
        }
        UILabel *label = [[UILabel alloc] initWithFrame:CGRectMake(15, 180 , kScreenWideth - 30, 40)];
        label.textColor = COLORFROMCODE(0x9B9B9B, 1);
        label.font = kFont(13);
        label.numberOfLines =0;
        label.text = @"密码由6-20位字符的字符和数字组成";
        [self addSubview:label];
    }
    return self;
}

/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
